<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:p="http://primefaces.org/ui"
	xmlns:ui="http://java.sun.com/jsf/facelets">


<ui:composition template="/template2.xhtml">
	<ui:define name="titulo">Cadastro de Veiculo</ui:define>
	<ui:define name="barra_titulo">Cadastro de Motorista</ui:define>
	<ui:define name="corpo">
		<h:form>

			<p:panel header=" " id="painel">
				<p:growl life="3000" />
				<h:panelGrid columns="2">
					<h:outputLabel value="Modelo:" />
					<p:inputText value="#{veiculoBean.veiculo.modelo}" />
					<h:outputLabel value="Placa:" />
					<p:inputMask value="#{veiculoBean.veiculo.placa}" mask="aaa-9999" />
					<h:outputLabel value="Porta:" />
					<p:inputText size="2" value="#{veiculoBean.veiculo.porta}" />
					<h:outputLabel value="Titular:" />
					<p:inputText value="#{veiculoBean.veiculo.titular}" />
				</h:panelGrid>
			</p:panel>
			<br />
			<p:commandButton value="Cadastrar"
				actionListener="#{veiculoBean.salvar}" update="painel" />
		</h:form>
	</ui:define>
</ui:composition>
</html>
